package entity;

import java.util.ArrayList;
import java.util.Collection;

public class ConsolidatedMthSalesFc implements Comparable {


    private Integer salesMonth;
    private Integer salesYear;
    private ArrayList <SalesForecast> salesForecasts;
    
     /* Additional fields to be added*/
    
    private String status;
    private String completed;
    
    /* /Additional fields to be added*/
    
    

    
    public ConsolidatedMthSalesFc (){}
    public ConsolidatedMthSalesFc (Integer salesMonth, Integer salesYear, ArrayList <SalesForecast> salesForecasts)
    {
        this.salesMonth = salesMonth;
        this.salesYear = salesYear;
        this.salesForecasts = salesForecasts;
    }
    
     @Override
    public int compareTo(Object obj) {
        ConsolidatedMthSalesFc  cfc = (ConsolidatedMthSalesFc ) obj;
        if (salesYear < cfc.salesYear) {
            return -1;
        } else if (salesYear > cfc.salesYear) {
            return 1;
        } else {
            if (salesMonth < cfc.salesMonth) {
                return -1;
            } else if (salesMonth > cfc.salesMonth) {
                return 1;
            } else {
               return 0;
            }
        }
    }
    

    /**
     * @return the salesMonth
     */
    public Integer getSalesMonth() {
        return salesMonth;
    }

    /**
     * @param salesMonth the salesMonth to set
     */
    public void setSalesMonth(Integer salesMonth) {
        this.salesMonth = salesMonth;
    }

    /**
     * @return the salesYear
     */
    public Integer getSalesYear() {
        return salesYear;
    }

    /**
     * @param salesYear the salesYear to set
     */
    public void setSalesYear(Integer salesYear) {
        this.salesYear = salesYear;
    }

    /**
     * @return the salesForecasts
     */
    public ArrayList <SalesForecast> getSalesForecasts() {
        return salesForecasts;
    }

    /**
     * @param salesForecasts the salesForecasts to set
     */
    public void setSalesForecasts(ArrayList <SalesForecast> salesForecasts) {
        this.salesForecasts = salesForecasts;
    }

    /**
     * @return the status
     */
    public String getStatus() {
        return status;
    }

    /**
     * @param status the status to set
     */
    public void setStatus(String status) {
        this.status = status;
    }

    /**
     * @return the completed
     */
    public String getCompleted() {
        return completed;
    }

    /**
     * @param completed the completed to set
     */
    public void setCompleted(String completed) {
        this.completed = completed;
    }
}
